$(function(){
	var myChart = echarts.init(document.getElementById("showEcharts"));
	var option = {
		tooltip : {
	        trigger: 'axis',
	        axisPointer : {             /*坐标轴指示器，坐标轴触发有效*/
	            type : 'shadow'        /*默认为直线，可选为：'line' | 'shadow'*/
	        }
	    },
		legend:{
			data:["及时建档儿童数","不及时儿童数","本地儿童数","县内流动儿童数","市内流动儿童数","省内流动儿童数","省外流动儿童数","港澳台儿童数","境外儿童数","其他"]
		},
		grid: { 
			right: '10%', 
			bottom:'35%'  
		}, 
		xAxis:{
			data:["淮海路接种门诊","矿医岱河分院","临涣镇卫生院","石台镇卫生院","淮北市疾控中心孟山中路接种门诊","矿医杨庄分院","青龙山社区中心","韩村镇卫生院","五沟镇卫生院","宋町镇卫生院","濉溪镇卫生院","矿医朔里分院"],
			axisLabel: {
				interval: 0,
	            rotate: -80
        	}
		},
		yAxis:{},
		series:[{
			name:"及时建档儿童数",
			type:"bar",
			stack:"建档儿童数",
			data:[5, 10, 20, 10, 10, 0, 5, 13, 8, 1, 10, 20]
			
		},{
			name:"不及时儿童数",
			type:"bar",
			stack:"建档儿童数",
			data:[2, 2, 10, 10, 0, 5, 0, 0, 8, 11, 5, 0]
		},{
			name:"本地儿童数",
			type:"bar",
			stack:"儿童地区分布",
			data:[2, 2, 7, 15, 0, 5, 1, 0, 4, 10, 15, 13]
			
		},{
			name:"县内流动儿童数",
			type:"bar",
			stack:"儿童地区分布",
			data:[2, 6, 7, 4, 10, 0, 2, 0, 2, 2, 0, 7]
		},{
			name:"市内流动儿童数",
			type:"bar",
			stack:"儿童地区分布",
			data:[2, 0, 14, 0, 0, 0, 0, 6, 1, 0, 0, 0]
			
		},{
			name:"省内流动儿童数",
			type:"bar",
			stack:"儿童地区分布",
			data:[0, 4, 1, 0, 0, 0, 0, 3, 1, 0, 0, 0]
		},{
			name:"省外流动儿童数",
			type:"bar",
			stack:"儿童地区分布",
			data:[1, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0]
			
		},{
			name:"港澳台儿童数",
			type:"bar",
			stack:"儿童地区分布",
			data:[0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0]
		},{
			name:"境外儿童数",
			type:"bar",
			stack:"儿童地区分布",
			data:[0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0]
			
		},{
			name:"其他",
			type:"bar",
			stack:"儿童地区分布",
			data:[0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0]
		}]
	};
	myChart.setOption(option);
	/*容器大小自适应*/
	window.onresize =  myChart.resize;
});